//导入请求工具
import request from '@/util/request';
//注册请求
export const userRegisterService = (registerData)=>{
    const params = new URLSearchParams();
    for(let key in registerData){
        params.append(key,registerData[key]);
    }
    return request.post('/user/register',params);
}
//登录请求
export const userLoginService = (loginData)=>{
    const params = new URLSearchParams();
    for(let key in loginData){
        params.append(key,loginData[key]);
    }
    return request.post('/user/login',params);
}
//获取用户详细信息请求
export const userInfoGetService=()=>{
    return request.get('/user/userInfo');
} 
//修改用户
export const userEditService=(userInfo)=>{
    return request.put('/user/update',userInfo);
}